package gov.chinatax.ctcps.generator.dao.pojo;

import java.io.Serializable;
import org.apache.commons.lang.builder.EqualsBuilder;
import org.apache.commons.lang.builder.HashCodeBuilder;
import org.apache.commons.lang.builder.ToStringBuilder;

/** 
 *        @hibernate.class
 *         table="DM_YSJC"
 *     
*/
public class DmYsjc implements Serializable {

    /** identifier field */
    private String ysjcDm;

    /** nullable persistent field */
    private String ysjcMc;

    /** full constructor */
    public DmYsjc(String ysjcDm, String ysjcMc) {
        this.ysjcDm = ysjcDm;
        this.ysjcMc = ysjcMc;
    }

    /** default constructor */
    public DmYsjc() {
    }

    /** minimal constructor */
    public DmYsjc(String ysjcDm) {
        this.ysjcDm = ysjcDm;
    }

    /** 
     *            @hibernate.id
     *             generator-class="assigned"
     *             type="java.lang.String"
     *             column="YSJC_DM"
     *         
     */
    public String getYsjcDm() {
        return this.ysjcDm;
    }

    public void setYsjcDm(String ysjcDm) {
        this.ysjcDm = ysjcDm;
    }

    /** 
     *            @hibernate.property
     *             column="YSJC_MC"
     *             length="30"
     *         
     */
    public String getYsjcMc() {
        return this.ysjcMc;
    }

    public void setYsjcMc(String ysjcMc) {
        this.ysjcMc = ysjcMc;
    }

    public String toString() {
        return new ToStringBuilder(this)
            .append("ysjcDm", getYsjcDm())
            .toString();
    }

    public boolean equals(Object other) {
        if ( !(other instanceof DmYsjc) ) return false;
        DmYsjc castOther = (DmYsjc) other;
        return new EqualsBuilder()
            .append(this.getYsjcDm(), castOther.getYsjcDm())
            .isEquals();
    }

    public int hashCode() {
        return new HashCodeBuilder()
            .append(getYsjcDm())
            .toHashCode();
    }

}
